The present invention relates to a sewing machine having a sewing device controlled by a processor, whereby the processor is capable of being switched over from one mode to another wherein in the first mode, control is effected by control programs for the sewing operations and in the second mode, control is effected by diagnostic programs. Sewing machines of this kind are known, e.g., from U.S. Pat. No. 4,393,796 and 4,480,561. However, the diagnostic capabilities of known machines have heretofore been fairly limited and they relate practically exclusively to the operability of certain machine parts.